import React from 'react';
import BaseScreen from "../BaseScreen";
import styles from "../../css/my.module.css"
import {Common_problems} from '../../service/TaskService'
import {navigateTo} from '../../utils/LocationUtil'
import * as locations from "../../const/locations";
import { myNav, Common } from "../../const/imgs";
import { locationTo, locationReplace } from "../../utils/LocationUtil";
import { clear, getID } from "../../utils/StorageUtil";
import Config from "../../Config";
import { MyButton } from "../../view/MyButton";
import { HintDialog } from "../../view/Dialog";
class SetScreen extends BaseScreen{
  constructor(props){
    super(props);
    this.state={
      problems:[]
    }
  }
 
  render() {
   
    return(
      <div className={styles.homes} 
      style={{
        boxSizing: 'border-box',
        paddingTop:'10px',
        paddingBottom:'100px',
        display:'flex',
        flexDirection:'column',
        justifyContent:'space-between'
    }}
      
      >
         <div className={styles["wrapper"]}>
          <ul>
            {NAVIGATORLIST.map((item, index) => (
              <Navlistone
                key={index}
                name={item.name}
                imgurl={item.imgurl}
                path={item.path}
              />
            ))}
          </ul>
        </div>
        {/* <MyButton
          style={styleBtn}
          name={"退出登录"}
          onClick={() => {
            this.handleSubmit();
          }}
        /> */}
      </div>
    )
  }
}

const Navlistone = ({ name, imgurl, path }) => {
  return (
    <li className={styles.nav_list_one} onClick={() => { locationTo(path) }}>
      <div className={styles.nav_list_one_l}>
        {name}
      </div>
      <div className={styles.nav_list_one_r}>
        <img src={Common.YJT} />
      </div>
    </li>
  );
}

const NAVIGATORLIST = [
  {
    id: 5,
    name: "修改密码",
    // imgurl: myNav.FORGOTPWD,
    path: locations.CHANGEPWD
  },
 ]
  const styleBtn = {
    height: "2.75rem",
    lineHeight: "2.75rem",
    width: "73.6%",
    padding: 0,
    margin: "4.5rem auto 0"
  };
export default SetScreen;